<template>
	<view class="container">
		<uni-section title="实心标签" type="line" padding>
					<view class="example-body">
						<view class="tag-view">
							<uni-tag text="标签" type="primary" />
						</view>
						<view class="tag-view">
							<uni-tag text="标签" type="success" />
						</view>
						<view class="tag-view">
							<uni-tag text="标签" type="warning" />
						</view>
						<view class="tag-view">
							<uni-tag text="标签" type="error" />
						</view>
						<view class="tag-view">
							<uni-tag text="标签" />
						</view>
					</view>
				</uni-section>

	</view>
</template>

<script>
	export default {
			components: {},
			data() {
				return {
					type: "default",
					inverted: false,
				};
			},
			methods: {
				setType() {
					let types = ["default", "primary", "success", "warning", "error"];
					let index = types.indexOf(this.type);
					types.splice(index, 1);
					let randomIndex = Math.floor(Math.random() * 4);
					this.type = types[randomIndex];
				},
				setInverted() {
					this.inverted = !this.inverted;
				},
			},
		};
</script>

<style>
</style>